package com.smallcc.exception;

import com.smallcc.enums.ResultEnum;
import lombok.Getter;

/**
 * @author 晓风过境
 * @TODO
 * @date 2018/3/29 14:06
 * @day 29
 * @return $text$
 * @title ${CLASS_NAME}
 * @project_name sell
 */
@Getter
public class SellException  extends RuntimeException{
    private Integer code;
    private String message;

    public SellException(ResultEnum resultEnum) {
        super(resultEnum.getMessage());
        this.code=resultEnum.getCode();
    }
    public SellException(Integer code,String message){
        super(message);
        this.code=code;
    }
}
